import type { CSSProperties } from "react";
import React from "react";

export type CascaderValue = string | number;

export type CascaderOptions = Array<{
  label: string;
  disabled?: boolean;
  value: CascaderValue;
  children?: Array<{ label: string; value: CascaderValue }>;
}>;

export interface CascaderProps {
  value?: Array<CascaderValue>;
  options?: CascaderOptions;
  disabled?: boolean;
  placeholder?: string;
  style?: CSSProperties;
  className?: string;
  changeOnSelect?: boolean;
  allowClear?: boolean;
  loadData?: (selectOptions: CascaderOptions) => void;
  onChange?: (v: Array<CascaderValue>) => void;
  notFoundContent?: string;
  placement?: "bottomLeft" | "bottomRight" | "topLeft" | "topRight";
}
